package edu.faytechcc.csc.chat;

import edu.faytechcc.csc.gui.ChatWindow;
import edu.faytechcc.csc.gui.ClientFrame;
import edu.faytechcc.csc.messages.Connection;
import java.io.IOException;
import java.net.Socket;
import java.net.UnknownHostException;

/**
 * Please describe what this class does here.
 *
 * CSC 251 0001 DATE:
 *
 * @author Stephanie Mckenzie
 */
public class ChatClient
{

    public static void main(String[] args) throws IOException
    {

        Socket socket = null;

        final String SERVER_IP = "192.168.0.6";

        try
        {
            socket = new Socket(SERVER_IP, 4444);
            System.out.println("Server connected: "
                    + socket.getInetAddress());
            System.out.println("+++++++++++++\n");

            Connection conn = new Connection(socket, "Server");
            conn.connect();

            ClientFrame frame = new ClientFrame(conn);
            
        } catch (UnknownHostException uhe)
        {
            System.err.println();
            System.exit(36);
        }
    }
}
